﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using WebServer.Models;

namespace WebServer.Biz
{
    public class Common
    {
        public static string SpecialKey(string Text)
        {
            if (Text == null)
            {
                return "";
            }
            else
            {
                WebConfiguration entity = new WebConfiguration();
                entity = new WebConfigurationBiz().MNWebConfiguration(false);

                string[] aa = entity.BlockKey.Split(',');

                foreach (var item in aa)
                {
                    if (Text.Contains(item))
                    {
                        if (item.Trim() == "")
                        { }
                        else
                        {
                            Text = Text.Replace(item, "**");
                        }
                    }
                }
                return Text;
            }
        }
    }
}
